<%@page import="java.util.List"%>
<%@page import="java.util.ArrayList"%>
<%@ page contentType="text/html; charset=UTF-8"%>
<%@ include file="/classes/CommonHelper.class.jsp"%>
<%@ include file="/classes/DBHelper.class.jsp"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%

	request.setCharacterEncoding("UTF-8");
	String loginId=(String)(session.getAttribute("loginId")==null?"":session.getAttribute("loginId"));
	if(nullOrEmpty(loginId)){
		out.print("<script>alert(\"请登陆后操作！\");</script>");
		out.print("<script>window.location.href = 'http://htgl.cnsn.gov.cn/cas/login';</script>");
		return;
	}
	
	String hzd = getParameter(request,"hzd");
	String sql = "select t1.*,t2.name bm_name from APP_SUGGESTION_BOX t1,cms_department t2 where t1.bm_id = t2.code_name and hzd = ?";
	
	Map<String,Object> m = getObject(sql,new Object[]{hzd});
	pageContext.setAttribute("m",m);
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<style type="text/css">
	* {
	padding:0;
	margin:0 auto;
} /* IE8*/
*+html * {
	padding:0;
	margin:0;
}
* {
	margin:0;
	padding:0;
}
body {
	margin:0px;
	font-size:12px;
	font-family:"宋体";
	color:#333;
	background:url(../images/bg02.jpg);
}
div {
	font-size:12px;
	text-align:left;
}
a {
	color:#333;
	text-decoration:none;
}
a:hover {
	color:#c00;
	text-decoration:none;
}
ul, li {
	padding:0px;
	margin:0px;
	list-style-type:none;
}
img {
	border:none;
}
div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, form, fieldset, input, textarea, blockquote {
	padding:0;
	margin:0;
}
table, td, tr, th {
	font-size:12px;
}
ul, li {
	margin:0px;
	padding:0px;
	list-style-type:none;
}
.clear {
	clear:both;
}
.transparent {
	background:transparent;
}
.left {
	float:left;
}
.right {
	float:right;
}

.white_font{font-size:14px; color:#fff;}
.table_td td{padding:4px; line-height:1.5;}
.div_cen{text-align:center; padding:5px 0; background:#87B1E3;}
	.jysz_nav_left{background:url(images/nav_left.jpg) no-repeat bottom left #EEF5FB; height:24px; line-height:24px; text-indent:10px; font-size:12px; color:#0065AB; font-weight:bold;border:1px solid #AACADF;position:relative; overflow:hidden}
	.jysz_nav_left a{color:#0065AB; font-weight:bold;}
	.jysz_nav222{ text-indent:34px; background:url(images/navfsdsds.jpg) no-repeat 15px 50%;line-height:24px; height:24px; font-size:12px; color:#333; font-family:"微软雅黑"; border:1px solid #AACADF; border-top:none; border-bottom:none;}
	.jysz_nav222 a{ font-size:12px;color:#333; font-family:"微软雅黑"; text-decoration:none;}
	.jysz_nav222 a:hover{text-decoration:none;color:#333;}
	
	
	.jysz_nav222ss{ text-indent:64px; background:url(images/navfsdsds.jpg) no-repeat 45px 50%;line-height:24px; height:24px; font-size:12px; color:#333; font-family:"微软雅黑"; border:1px solid #AACADF; border-top:none; border-bottom:none;}
	.jysz_nav222ss a{ font-size:12px;color:#333; font-family:"微软雅黑";}
	.jysz_nav222ss a:hover{text-decoration:none;color:#c30;}
	</style>
</head>
<body style="background-color: ">
<div style="height:20px; font-size:1px;"></div>
<form action="xxgkyjx_hfdo.class.jsp" method="post" name="myForm">
	<table border="1" align="center" cellpadding="2" cellspacing="0" bordercolor="#CCCCCC" style="BORDER-COLLAPSE: collapse" width="100%" class="table_td">
		<colgroup>
			<col style="background-color: blue"/>
			<col />
		</colgroup>
		<tr>
			<td bgcolor="#5D8DD7"  height="23" align="center">标题</td><td style="padding-left:10px;">${m.title }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">姓名</td><td style="padding-left:10px;">${m.xingm }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">联系电话</td><td style="padding-left:10px;">${m.lxdh }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">联系地址</td><td style="padding-left:10px;">${m.lxdz }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">邮箱</td><td style="padding-left:10px;">${m.yx }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">留言内容</td><td style="padding-left:10px;">${m.content }</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">留言时间</td><td style="padding-left:10px;">
			<c:if test="${!empty m.addtime }">
			<fmt:formatDate value="${m.addtime }" pattern="yyyy-MM-dd HH:mm:ss"/>
			</c:if>
			</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center">所属部门</td><td style="padding-left:10px;">${m.bm_name }</td>
		</tr>
		<tr>
			<td height="150px" bgcolor="#5D8DD7" align="center">回复内容</td><td style="padding-left:10px;">
				<c:if test="${empty m.content_hf }">
					<textarea name="content_hf" style="width: 300px;height: 150px"></textarea>
				</c:if>
				<c:if test="${!empty m.content_hf }">
				${m.content_hf  }
				</c:if>
			</td>
		</tr>
		<tr>
			<td bgcolor="#5D8DD7" height="23" align="center" style="padding-left:10px;">回复时间</td><td style="padding-left:10px;">
			<c:if test="${!empty m.addtime }">
			<fmt:formatDate value="${m.hftime }" pattern="yyyy-MM-dd HH:mm:ss"/>
			</c:if>
			</td>
		</tr>
		<tr>
			<td colspan="2" style="background-color:#ffffff" align="center">
			<input type="hidden" name="hzd" value="${m.hzd }" />
			<c:if test="${empty m.content_hf }">
			<input style="width:60px;" type="submit" value="提交" />
			</c:if> 
			<c:if test="${!empty m.content_hf }">
			<input style="width:60px;" type="button" value="返回" onclick="window.location.href='xxgkyjx_list.jsp?r=<%=new Date().getTime()%>'" />
			</c:if> 
			</td>
		</tr>
	</table>
	</form>
</body>
</html>
